package com.dxj.request;
import com.dxj.domain.User;
import io.github.linpeilie.annotations.AutoMapper;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import javax.validation.constraints.Email;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import java.util.List;

/**
 * @author dxj
 * @Description 用户注册入参
 * @date 2024/7/29 16:39
 */
@Data
@AutoMapper(target = User.class)
public class UserDTO {
    /**
     * 用户名
     */
    @ApiModelProperty(value = "用户名", required = true, example = "赵丽颖")
    @NotBlank(message = "用户名不能为空")
    private String userName;

    /**
     * 真实名称
     */
    @ApiModelProperty(value = "用户名", required = true, example = "mrs赵")
    private String nickName;
    /**
     * 密码
     */
    @ApiModelProperty(value = "密码", required = true, example = "123456")
    @NotBlank(message = "密码不能为空")
    private String passWord;

    /**
     * 邮箱
     */
    @ApiModelProperty(value = "邮箱", required = true, example = "1123@qq.com")
    @Email(message = "邮箱格式不正确")
    @NotBlank(message = "邮箱不能为空")
    private String email;

    /**
     * 角色id集合
     */
    @ApiModelProperty(value = "角色id集合", required = true, example = "[1,2,3]")
    @NotEmpty(message="角色id集合不为空")
    private List<Long> roleIds;

//    /**
//     * 校验 创建分组
//     */
//    public interface Create{}
//
//    /**
//     * 校验 更新分组
//     */
//    public interface Update{}
}
